FROM registry.cn-hangzhou.aliyuncs.com/migo-dl/python:3.10.18-poetry-0-4-1-amd64

ENV LANG=C.UTF-8 \
    TZ=Asia/Shanghai

WORKDIR /app

# 先仅拷贝依赖文件以最大化缓存命中
# 如使用 requirements.txt，请确保它在项目根目录
COPY . .

RUN poetry install

# 暴露端口（如需对外服务）；没有服务可删除
EXPOSE 50051

CMD ["poetry","run","cartpole"]
